<?php
declare (strict_types = 1);

namespace app\adminapi\model\Admin;

use adminmatrix\admin\model\BaseModel;
use think\Model;
use think\model\relation\HasOne;

/**
 * @mixin \think\Model
 */
class AdminSession extends BaseModel
{
    #------------------------------------------------------------
    #
    #   关联模型
    #
    #------------------------------------------------------------

    # 关联管理员
    public function admin() : HasOne
    {
        return $this->hasOne(Admin::class , 'id','admin_id')->append(['role_id']);
    }
}
